package com.zhuss.controller.advice;

import com.zhuss.advice.proposalSon.ProposalSonOperateServiceExt;
import com.zhuss.bean.bo.advice.proposal.CreateProposalBo;
import com.zhuss.bean.bo.advice.proposalSon.CreateProposalSonBo;
import com.zhuss.common.BaseController;
import com.zhuss.common.OperateService;
import com.zhuss.exception.WpsException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.web.bind.annotation.*;

/**
 * @Author: zhushanshuo
 * @Date: 2020/3/6 16:38
 */
@RestController
@RequestMapping("/proposalSon")
public class ProposalSonOperateController extends BaseController {

    @Autowired
    @Qualifier("proposalSonOperateService")
    private OperateService<Void, Object> proposalSonOperateService;

    @Autowired
    @Qualifier("proposalSonOperateServiceExt")
    private ProposalSonOperateServiceExt proposalSonOperateServiceExt;

    /**
     * 新建
     * @throws WpsException
     */
    @ResponseBody
    @PostMapping("/create")
    public void create(@RequestBody CreateProposalSonBo bo) throws WpsException {
        proposalSonOperateService.create(bo);
    }
}
